The present invention relates to a method, an arrangement, a computer program and a computer-readable storage medium for scaling two-dimensional structures, which is especially usable for resizing digital 2D images with a rational scaling factor.
The following discussion of related art is provided to assist the reader in understanding the advantages of the invention, and is not to be construed as an admission that this related art is prior art to this invention.
From conventional solutions is known a method for scaling (resizing) images by rational scaling factors. 2D image resizing is an important issue for pixel oriented displays with variable input formats. A special problem arises if low-resolution pictures shall be displayed on high-resolution screens, especially when only simple up-conversation methods like pixel and line repetition or bi-linear interpolation is used. Even when applying separable polyphase up-conversion filters, the problem of jagged lines (staircases) remains.
One of the conventional approaches for image scaling is shown in FIG. 1. According to the conventional scaling in a first step the input signal is interpolated with a factor L, then the resulting signal is filtered by a 2D low pass filter, and finally the signal is reduced by a factor M. FIG. 1 depicts a conventional method using a special filter, a so-called diamond filter. The up-scaling by a factor L includes pixel and line repetition in the source image by the factor L, which is known as sample and hold (S & H) (in FIG. 1 a factor L=3 is illustrated). Then a non-separable so-called diamond-shaped filter with identical coefficients is used followed by a down-sampling step by a factor M, therefore realizing a rational scaling factor L/M.
Another prior art resizing method uses very simple, non-separable filters, and which is suitable for image and video material such as analogue sources (PAL [=Phase Alternation Line], NTSC [=National Television Systems Committee]), digital sources (JPEG [=Joint Photographic Experts Group], MPEG [=Moving Picture Experts Group]), low-resolution up to high-resolution images, and noisy pictures. An essential feature of the method is that for calculation of a pixel of the target image only a (limited) maximal number of adjacent pixels of the source image is necessary. This is reached by using a so-called diamond-shaped filter. However, the size of the used diamond-shaped filter has a quadratic dependence of the factor of interpolation. Thus, also the computational load increases as the square of the factor of interpolation.
It has been also been reported that for several factors of interpolation the computational load converges towards a limit. However, the computational load still remains high.
It would therefore be desirable and advantageous to obviate prior art shortcomings and to provide an improved method, an arrangement, a computer program and a computer-readable storage medium for scaling two-dimensional structures, which more particularly reduces the arithmetic operations to a pre-definable fix value.